SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO

CREATE PROCEDURE GetUserByUserId
	@UserId	bigint
AS
BEGIN
	SELECT TOP 1 UserId, Email, Password, Username, IsDeleted, Created FROM Users WHERE UserId = @UserId AND IsDeleted = 0 ORDER BY Created DESC
END
GO
